package edu.spec.wfl.week08.class2.book.unit4.one;

public class Circle {
    private double radius;

    public Circle() {
    }

    public Circle(double r) {
        this.radius = r;
    }

    public double getArea(){
        double area = 3.14*radius*radius;
        return area;
    }

    public double getPerimeter(){
        double perimeter = 2*3.14*radius;
        return perimeter;
    }

    public void show(){
        System.out.println("半径：" + radius);
        System.out.println("周长：" + getPerimeter());
        System.out.println("面积：" + getArea());
    }
}
